def run(params:list[str]):
    from ApiTools import apiTools,apiBase
    from ApiModels import apiModels
    import json
    #是dir 还是QA
    #多个向量库采用；分割
    collects=apiBase.argv_array(params,1,'rft/relevancy;')
    usr_prompt=apiBase.argv(params,2,"The FIFA World Cup in 2018")
    type=apiBase.argv_int(params,3,0)
    ids=apiBase.argv_array(params,4)
    try:
        vectdb = apiTools.load_vec()
        
        vcts=apiTools.load_models().get_vects(collects,ids)
        txts=vectdb.clts_query(vcts, usr_prompt=usr_prompt,fun_name="rft-doc",type=type)
        ret=json.dumps(txts, ensure_ascii=False)
        #print(ret) 
        return ret  
    except Exception as e:
        return f"function error:{e}"
#run([])